package com.registration.bean;


import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.Column;
import java.util.Date;

public class OrderBean {
    //挂号订单
    private Long order_id;//订单 ID（自增）
    private String  order_no;//订单编号（唯一，如：REG202408100001）
    private Integer  user_id;//ID（外键关联 user 表）
    private Integer  patient_id;//就诊人 ID（外键关联 patient 表）
    private Integer  dept_id;//科室 ID（外键关联 department 表）
    private Integer  doctor_id;//医生 ID（外键关联 doctor 表）
    private Integer schedule_id;//排班 ID（外键关联 schedule 表）
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date visit_date;//就诊日期（与排班表一致）
    private Integer time_slot;//时间段（与排班表一致）
    private String visit_no;//就诊序号（如：上午 05 号）
    private String symptoms;//症状描述（用户填写）
    private Double  amount;//订单金额（与挂号费用一致）
    private Integer  order_status;//订单状态（0 - 待支付，1 - 已支付，2 - 已取消，3 - 已完成）
    private Integer  pay_status;//支付状态（0 - 未支付，1 - 已支付）
    private Date  pay_time;//支付时间（支付成功时记录）
    private Date  cancel_time;//取消时间（取消订单时记录）
    private Date visit_time;//实际就诊时间（医生确认后记录）
    private Date  create_time;//订单创建时间
    private Date update_time;//订单更新时间（状态变动时更新）

    private String patient_name;//就诊人名称 patient_name
    private String dept_name;
    private String doctor_name;

    @Override
    public String toString() {
        return "OrderBean{" +
                "order_id=" + order_id +
                ", order_no='" + order_no + '\'' +
                ", user_id=" + user_id +
                ", patient_id=" + patient_id +
                ", dept_id=" + dept_id +
                ", doctor_id=" + doctor_id +
                ", schedule_id=" + schedule_id +
                ", visit_date=" + visit_date +
                ", time_slot=" + time_slot +
                ", visit_no='" + visit_no + '\'' +
                ", symptoms='" + symptoms + '\'' +
                ", amount=" + amount +
                ", order_status=" + order_status +
                ", pay_status=" + pay_status +
                ", pay_time=" + pay_time +
                ", cancel_time=" + cancel_time +
                ", visit_time=" + visit_time +
                ", create_time=" + create_time +
                ", update_time=" + update_time +
                ", patient_name='" + patient_name + '\'' +
                ", dept_name='" + dept_name + '\'' +
                ", doctor_name='" + doctor_name + '\'' +
                '}';
    }



    private String doctor_title; // 医生职称
    private String doctor_avatar; // 医生头像URL
    private String queue_number; // 排队号码
    private Integer queue_status; // 排队状态

    public String getDoctor_title() {
        return doctor_title;
    }

    public void setDoctor_title(String doctor_title) {
        this.doctor_title = doctor_title;
    }

    public String getDoctor_avatar() {
        return doctor_avatar;
    }

    public void setDoctor_avatar(String doctor_avatar) {
        this.doctor_avatar = doctor_avatar;
    }

    public String getQueue_number() {
        return queue_number;
    }

    public void setQueue_number(String queue_number) {
        this.queue_number = queue_number;
    }

    public Integer getQueue_status() {
        return queue_status;
    }

    public void setQueue_status(Integer queue_status) {
        this.queue_status = queue_status;
    }

    public String getPatient_name() {
        return patient_name;
    }

    public void setPatient_name(String patient_name) {
        this.patient_name = patient_name;
    }

    public String getDept_name() {
        return dept_name;
    }

    public void setDept_name(String dept_name) {
        this.dept_name = dept_name;
    }

    public String getDoctor_name() {
        return doctor_name;
    }

    public void setDoctor_name(String doctor_name) {
        this.doctor_name = doctor_name;
    }

    public Long getOrder_id() {
        return order_id;
    }

    public void setOrder_id(Long order_id) {
        this.order_id = order_id;
    }

    public String getOrder_no() {
        return order_no;
    }

    public void setOrder_no(String order_no) {
        this.order_no = order_no;
    }

    public Integer getUser_id() {
        return user_id;
    }

    public void setUser_id(Integer user_id) {
        this.user_id = user_id;
    }

    public Integer getPatient_id() {
        return patient_id;
    }

    public void setPatient_id(Integer patient_id) {
        this.patient_id = patient_id;
    }

    public Integer getDept_id() {
        return dept_id;
    }

    public void setDept_id(Integer dept_id) {
        this.dept_id = dept_id;
    }

    public Integer getDoctor_id() {
        return doctor_id;
    }

    public void setDoctor_id(Integer doctor_id) {
        this.doctor_id = doctor_id;
    }

    public Integer getSchedule_id() {
        return schedule_id;
    }

    public void setSchedule_id(Integer schedule_id) {
        this.schedule_id = schedule_id;
    }

    public Date getVisit_date() {
        return visit_date;
    }

    public void setVisit_date(Date visit_date) {
        this.visit_date = visit_date;
    }

    @Column(name = "time_slot")
    public Integer getTime_slot() {
        return time_slot;
    }

    public void setTime_slot(Integer time_slot) {
        this.time_slot = time_slot;
    }

    public String getVisit_no() {
        return visit_no;
    }

    public void setVisit_no(String visit_no) {
        this.visit_no = visit_no;
    }

    public String getSymptoms() {
        return symptoms;
    }

    public void setSymptoms(String symptoms) {
        this.symptoms = symptoms;
    }

    public Double getAmount() {
        return amount;
    }

    public void setAmount(Double amount) {
        this.amount = amount;
    }

    public Integer getOrder_status() {
        return order_status;
    }

    public void setOrder_status(Integer order_status) {
        this.order_status = order_status;
    }

    public Integer getPay_status() {
        return pay_status;
    }

    public void setPay_status(Integer pay_status) {
        this.pay_status = pay_status;
    }

    public Date getPay_time() {
        return pay_time;
    }

    public void setPay_time(Date pay_time) {
        this.pay_time = pay_time;
    }

    public Date getCancel_time() {
        return cancel_time;
    }

    public void setCancel_time(Date cancel_time) {
        this.cancel_time = cancel_time;
    }

    public Date getVisit_time() {
        return visit_time;
    }

    public void setVisit_time(Date visit_time) {
        this.visit_time = visit_time;
    }

    public Date getCreate_time() {
        return create_time;
    }

    public void setCreate_time(Date create_time) {
        this.create_time = create_time;
    }

    public Date getUpdate_time() {
        return update_time;
    }

    public void setUpdate_time(Date update_time) {
        this.update_time = update_time;
    }
}
